package framework.event;

import framework.api.KieBaseConfiguration.KieBaseOption;
public enum DeclarativeAgendaOption implements KieBaseOption{
    ENABLED(true), DISABLED(false);
    private boolean value;

    DeclarativeAgendaOption(final boolean value) {
        this.value = value;
    }

    public static DeclarativeAgendaOption determineDeclarativeAgenda(String option) {
        if ( ENABLED.name().equalsIgnoreCase(option) || "true".equalsIgnoreCase(option) ) {
            return ENABLED;
        } else if ( DISABLED.name().equalsIgnoreCase(option) || "false".equalsIgnoreCase(option) ) {
            return DISABLED;
        }
        throw new IllegalArgumentException( "Illegal enum value '" + option + "' for DeclarativeAgendaOption" );
    }
}
